{"ast":null,"code":"var _jsxFileName = \"/data/messenger.client/src/components/DropDownMenu/index.tsx\",\n  _s = $RefreshSig$();\nimport React from 'react';\nimport \"./DropDownMenu.scss\";\nimport { jsxDEV as _jsxDEV } from \"react/jsx-dev-runtime\";\nconst DropDownMenu = _ref => {\n  _s();\n  let {\n    children\n  } = _ref;\n  const [show, setShow] = React.useState(false);\n  React.useEffect(() => {\n    setShow(false);\n  }, [children]);\n  return /*#__PURE__*/_jsxDEV(\"div\", {\n    className: \"dropDownMenu\",\n    children: [/*#__PURE__*/_jsxDEV(\"button\", {\n      onClick: () => setShow(!show),\n      className: \"dropDownMenu__button\"\n    }, void 0, false, {\n      fileName: _jsxFileName,\n      lineNumber: 17,\n      columnNumber: 13\n    }, this), show && /*#__PURE__*/_jsxDEV(\"div\", {\n      className: \"dropDownMenu__children\",\n      children: children\n    }, void 0, false, {\n      fileName: _jsxFileName,\n      lineNumber: 19,\n      columnNumber: 17\n    }, this)]\n  }, void 0, true, {\n    fileName: _jsxFileName,\n    lineNumber: 16,\n    columnNumber: 9\n  }, this);\n};\n_s(DropDownMenu, \"bXBd/WbmO9A8Q7bxaOKZvuJyGc0=\");\n_c = DropDownMenu;\nexport default DropDownMenu;\nvar _c;\n$RefreshReg$(_c, \"DropDownMenu\");","map":{"version":3,"names":["React","DropDownMenu","children","show","setShow","useState","useEffect"],"sources":["/data/messenger.client/src/components/DropDownMenu/index.tsx"],"sourcesContent":["import React from 'react';\nimport \"./DropDownMenu.scss\";\n\ntype Props = {\n    children: React.ReactNode;\n};\n\nconst DropDownMenu: React.FC<Props> = ({children}) => {\n    const [show, setShow] = React.useState<boolean>(false);\n\n    React.useEffect(() => {\n        setShow(false);\n    }, [children]);\n\n    return (\n        <div className=\"dropDownMenu\">\n            <button onClick={() => setShow(!show)} className=\"dropDownMenu__button\" />\n            {show &&\n                <div className=\"dropDownMenu__children\">\n                    {children}\n                </div>\n            }\n        </div>\n    );\n}\n\nexport default DropDownMenu;\n"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAO,qBAAqB;AAAC;AAM7B,MAAMC,YAA6B,GAAG,QAAgB;EAAA;EAAA,IAAf;IAACC;EAAQ,CAAC;EAC7C,MAAM,CAACC,IAAI,EAAEC,OAAO,CAAC,GAAGJ,KAAK,CAACK,QAAQ,CAAU,KAAK,CAAC;EAEtDL,KAAK,CAACM,SAAS,CAAC,MAAM;IAClBF,OAAO,CAAC,KAAK,CAAC;EAClB,CAAC,EAAE,CAACF,QAAQ,CAAC,CAAC;EAEd,oBACI;IAAK,SAAS,EAAC,cAAc;IAAA,wBACzB;MAAQ,OAAO,EAAE,MAAME,OAAO,CAAC,CAACD,IAAI,CAAE;MAAC,SAAS,EAAC;IAAsB;MAAA;MAAA;MAAA;IAAA,QAAG,EACzEA,IAAI,iBACD;MAAK,SAAS,EAAC,wBAAwB;MAAA,UAClCD;IAAQ;MAAA;MAAA;MAAA;IAAA,QACP;EAAA;IAAA;IAAA;IAAA;EAAA,QAER;AAEd,CAAC;AAAA,GAjBKD,YAA6B;AAAA,KAA7BA,YAA6B;AAmBnC,eAAeA,YAAY;AAAC;AAAA"},"metadata":{},"sourceType":"module"}